<template>
	<view class='p_30'>
	  <view class='courseBox' v-for="(course, index) in courses" :key="index">
	    <view class='leftCont'>
	      <image :src='course.img'></image>
	    </view>
	    <view class='rightCont'>
	      <view>
	        <view class='fs_30'>{{course.title}}</view>
	        <view class='orderInfo color_9d'>{{course.score}}分 | {{course.num}}人预约</view>
	      </view>
	      <view class='justify_between'>
	        <view class='price'>￥{{course.current}}<text>￥{{course.original}}</text></view>
	        <button class="bookBtn" hover-class='btn_hover'>点击预约</button>
	      </view>
	    </view>
	  </view>
	</view>
</template>

<script>
	export default {
		data() {
			return {
				courses: [
					{
						img: '../../static/img_kecheng2x.png',
						title: '英语零基础直达大学四级',
						score: 4.0,
						num: 960,
						current: 299,
						original: 399
					},
					{
						img: '../../static/img_kecheng2x.png',
						title: '英语零基础直达大学四级',
						score: 4.5,
						num: 1020,
						current: 399,
						original: 499
					},
					{
						img: '../../static/img_kecheng2x.png',
						title: '英语零基础直达大学四级',
						score: 4.2,
						num: 820,
						current: 199,
						original: 299
					}
				]
			}
		},
		methods: {
			
		}
	}
</script>

<style>
	.courseBox {
	  display: flex;
	  background: #fff;
	  padding: 30rpx;
	  margin-bottom: 20rpx;
	  border-radius: 10rpx;
	}
	
	.leftCont image {
	  width: 220rpx;
	  height: 162rpx;
	  display: block;
	}
	
	.cardImg {
	  width: 294rpx;
	  height: 194rpx;
	}
	
	.rightCont {
	  width: 100%;
	  margin-left: 30rpx;
	  display: flex;
	  flex-direction: column;
	  justify-content: space-between;
	}
	
	.notFull {
	  color: #ec691a;
	}
	
	.full {
	  color: #aaa;
	}
	
	.orderInfo {
	  font-size: 24rpx;
	  line-height: 2;
	}
	
	.price {
	  font-size: 34rpx;
	  color: #f14927;
	}
	
	.price text {
	  font-size: 24rpx;
	  color: #9D9D9D;
	  text-decoration: line-through;
	}
	.bookBtn{
	  font-size: 22rpx;
	  color: #2A93FE;
	  padding: 0 10rpx;
	  margin: 0;
	  border: 1rpx solid #2A93FE;
	  background-color: #fff;
	  line-height: 2;
	}
	.btn_hover{
	  opacity: 0.6;
	}

</style>
